package com.lightjet.macross.base.upms.service.impl;

import com.lightjet.macross.base.upms.domain.SysOrganization;
import com.lightjet.macross.base.upms.repository.SysOrganizationRepository;
import com.lightjet.macross.base.upms.service.SysOrganizationService;
import com.lightjet.macross.common.core.BaseServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SysOrganizationServiceImpl extends BaseServiceImpl<SysOrganization,String> implements SysOrganizationService {

    @Override
    public SysOrganization FindDistinctById(String id) {
        return ((SysOrganizationRepository)baseRepository).findDistinctById(id);
    }

    @Override
    public SysOrganization FindDistinctByOrgancode(String code) {
        return ((SysOrganizationRepository)baseRepository).findDistinctByOrgancode(code);
    }

    @Override
    public List<SysOrganization> FindByKeywords(String keywords) {
        return ((SysOrganizationRepository)baseRepository).findByKeywords(keywords);
    }

    @Override
    public List<SysOrganization> FindRootOrgs() {
        return ((SysOrganizationRepository)baseRepository).findRootOrgs();
    }
}
